<!DOCTYPE html>
<html lang="zh-CN">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <meta http-equiv="X-UA-Compatible" content="ie=edge" />
    <title>Document</title>
    <script src="../lib/vue.js"></script>
  </head>

  <body>
    <div id="app">
      <!-- 01.遍历对象的过程中，如果只是获取一个值，获取到的是value-->
      <ul>
        <li v-for="item in info">
          {{item}}
        </li>
      </ul>
      <!-- 02.遍历对象的过程中，value 和 key-->
      <ul>
        <li v-for="(item,key) in info">
          {{item}} - {{key}}
        </li>
      </ul>
    </div>

    <script>
      var vm = new Vue({
        el: '#app',
        data: {
          info: {
            name: 'sc',
            age: '19',
            sexy: '男'
          }
        },
        methods: {}
      })
    </script>
  </body>
</html>
